package com.project.bean;

import java.time.LocalDate;

/**
 * 学生实体类
 */
public class StudentBean {
    //学生id
    private Integer id;
    //学生姓名
    private String studentName;
    //学生电话
    private String studentPhone;
    //学生性别
    private String sex;
    //学生班级
    private ClassBean classBean;
    //学生房间
    private RoomBean roomBean;
    //学生入住时间
    private LocalDate studentDate = LocalDate.now();
    //学生头像
    private String studentImg;

    public StudentBean () {}

    public StudentBean(String studentName, String studentPhone, String sex, String studentImg, Integer classId, Integer roomId ) {
        this.studentName = studentName;
        this.studentPhone = studentPhone;
        this.sex = sex;
        ClassBean classBean1 = new ClassBean();
        classBean1.setId(classId);
        this.classBean=classBean1;
        RoomBean roomBean1 = new RoomBean();
        roomBean1.setId(roomId);
        this.roomBean=roomBean1;
        this.studentImg = studentImg;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getStudentName() {
        return studentName;
    }

    public void setStudentName(String studentName) {
        this.studentName = studentName;
    }

    public String getStudentPhone() {
        return studentPhone;
    }

    public void setStudentPhone(String studentPhone) {
        this.studentPhone = studentPhone;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public ClassBean getClassBean() {
        return classBean;
    }

    public void setClassBean(ClassBean classBean) {
        this.classBean = classBean;
    }

    public RoomBean getRoomBean() {
        return roomBean;
    }

    public void setRoomBean(RoomBean roomBean) {
        this.roomBean = roomBean;
    }

    public LocalDate getStudentDate() {
        return studentDate;
    }

    public void setStudentDate(LocalDate studentDate) {
        this.studentDate = studentDate;
    }

    public String getStudentImg() {
        return studentImg;
    }

    public void setStudentImg(String studentImg) {
        this.studentImg = studentImg;
    }

    @Override
    public String toString() {
        return "StudentBean{" +
                "id=" + id +
                ", studentName='" + studentName + '\'' +
                ", studentPhone='" + studentPhone + '\'' +
                ", sex='" + sex + '\'' +
                ", classBean=" + classBean +
                ", roomBean=" + roomBean +
                ", studentDate=" + studentDate +
                ", studentImg='" + studentImg + '\'' +
                "}\n";
    }
}
